import { Store } from 'pinia'
import { BaseModelType } from '@common'
import { BaseModelTreeType, BaseModelTreeNodeType } from '@renderer/types'

type StorePickType = Pick<
  {
    getMap: () => Record<string, BaseModelType>
    getList: () => BaseModelTreeType
    getTree: () => BaseModelTreeType
    getDirTree: () => BaseModelTreeType
    getTreeMapAll: () => Record<string, BaseModelTreeNodeType>
    getTreeMap: () => Record<string, BaseModelTreeNodeType>
    load: () => Promise<void>
  },
  any
>

export type StoreType = Store<string, StorePickType, StorePickType, StorePickType>
